package oop;

public class Student {
    //成员变量
    private String name;
    public void sing(){
        System.out.println(this);
       //String name="凡凡";
        //打印局部变量的值
        System.out.println(this.name);
        //打印一下  成员变量的值
        System.out.println(this.name);

    }

    public String getName() {
        //this.sing();
        return this.name;
    }

    public void setName(String name) {
        this.name = name;
    }
}
